//
//  CouponVC.m
//  HappyRent
//
//  Created by CoderYee on 2017/4/7.
//  Copyright © 2017年 内圈科技. All rights reserved.
//

#import "CouponVC.h"
#import "Coupon_SubVC.h"   //优惠券VC
#import "YeeContainScrollView.h"
@interface CouponVC ()

@end

@implementation CouponVC

-(void)addNavbarView{
    
    [super addNavbarView];
    
    self.title=@"优惠券";
}

-(void)configOwnViews{
    
    [super configOwnViews];
}
-(void)addOwnViews{
    
    [super addOwnViews];
    
    [self addContainView];
}
#pragma mark 添加子类视图
-(void)addContainView{
    
    NSArray *titleArray=@[@"未使用(1)",@"已使用(2)",@"已过期(5)"];
    NSMutableArray  *views=[[NSMutableArray alloc] init];
    for (NSInteger i=0; i<3; i++) {
        
        Coupon_SubVC *Vc=[[Coupon_SubVC  alloc] init];
        [views addObject:Vc.view];
        [self addChildViewController:Vc];
        
    }
    YeeContainScrollView  *scollView=[[YeeContainScrollView alloc] initWithFrame:self.view.bounds  withViews:views withTitles:titleArray];
    [self.view addSubview:scollView];
    
}


@end
